home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / C and C++ / Libraries / stringsearch / bmsource / sys / 386.c < prev    next >
Encoding:
C/C++ Source or Header  |  1990-11-21  |  248 b   |  22 lines  |  [TEXT/MPS ]

  1. #include    <sys/types.h>
  2. #include    <sys/times.h>
  3. #include    <sys/param.h>
  4.  
  5. int hz = HZ;
  6. double tcmp = 4.91;
  7.  
  8. static struct tms start;
  9.  
  10. startclock()
  11. {
  12.     times(&start);
  13. }
  14.  
  15. stopclock()
  16. {
  17.     struct tms t;
  18.  
  19.     times(&t);
  20.     return(t.tms_utime - start.tms_utime);
  21. }
  22.